package first.niuke.huawei.simple;

import java.util.Scanner;

/**
 * @ClassName HJ108
 * @description:
 * @author: 荣燊
 * @create: 2021-07-02 15:24
 **/
public class HJ108 {
    // 求最小公倍数 ,(a*b)/最大公约数

    // A,B,先求出最大公约数
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            int a = scanner.nextInt();
            int b = scanner.nextInt();

            System.out.println( (a*b) / function1(Math.max(a,b),Math.min(a,b))  );
        }
    }

    static int function(int a, int b) {
        int max = Math.max(a, b);
        int min = Math.min(a, b);
        // 欧几里得算法（辗转相除法）
        while (min != 0) {
            int tmp = max % min;
            max = min;
            min = tmp;
        }
        return max;
    }

    static int function1(int a, int b) {
        if (b == 0) {
            return a;
        }
        return function1(b, a%b);
    }

}
